package com.heima.model.admin.dtos;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;

@Data
@ApiModel(value = "管理员登陆实体")
public class AdUserDto {
    @NotNull(message = "用户名不能为空")
    @NotBlank(message = "用户名不能为空")
    @ApiModelProperty(value = "姓名")
    private String name;
    @NotNull(message = "密码不能为空")
    @Length(min = 5,max = 20,message = "密码长度在5-20个长度")
    @ApiModelProperty(value = "密码")
    private String password;
}
